#!/usr/bin/perl
#session-lib.pl

do '../web-lib.pl';
&init_config();

sub mdm_settimeout
{
my $timeout = $_[0];

$timeout = "" if ($timeout == 0);
&lock_file($ENV{'MINISERV_CONFIG'});
&get_miniserv_config(\%miniserv);
$miniserv{'logouttime'} = ($timeout ne "")?$timeout:undef;
&put_miniserv_config(\%miniserv);
&unlock_file($ENV{'MINISERV_CONFIG'});
&restart_miniserv();
return "Success";
}

1;

